package com.selfmedia.common.type;

public enum AccountType {
    pb_video_type(1,"发布视频工具"),;

    private Integer value;
    private String name;

    AccountType(int value, String name) {
        this.value = value;
        this.name = name;
    }

    public Integer getValue() {
        return value;
    }
    public String getName() {
        return name;
    }
    public static AccountType parse(int value) {
        for (AccountType accountType : values()) {
            if (accountType.getValue() == value) return accountType;
        }
        return null;
    }
    public static AccountType parseName(String name) {
        for (AccountType accountType : values()) {
            if (accountType.getName().equals(name)) return accountType;
        }
        return null;
    }

}
